<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE HTML>
<html>
<head>
    <meta charset="utf-8">
    <meta name="renderer" content="webkit|ie-comp|ie-stand">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport"
          content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no"/>
    <meta http-equiv="Cache-Control" content="no-siteapp"/>
    <!--[if lt IE 9]>
    <script type="text/javascript" src="lib/html5shiv.js"></script>
    <script type="text/javascript" src="lib/respond.min.js"></script>
    <![endif]-->
    <link rel="stylesheet" type="text/css" href="static/h-ui/css/H-ui.min.css"/>
    <link rel="stylesheet" type="text/css" href="static/h-ui.admin/css/H-ui.admin.css"/>
    <link rel="stylesheet" type="text/css" href="lib/Hui-iconfont/1.0.8/iconfont.css"/>
    <link rel="stylesheet" type="text/css" href="static/h-ui.admin/skin/default/skin.css" id="skin"/>
    <link rel="stylesheet" type="text/css" href="static/h-ui.admin/css/style.css"/>
    <link rel="stylesheet" href="lib/zTree/v3/css/zTreeStyle/zTreeStyle.css" type="text/css">
    <!--[if IE 6]>
    <script type="text/javascript" src="lib/DD_belatedPNG_0.0.8a-min.js"></script>
    <script>DD_belatedPNG.fix('*');</script>
    <![endif]-->
    <title>设置时间</title>
</head>
<style>
    .table > tbody > tr > td {
        text-align: center;
    }
</style>
<body>
<div class="page-container">
    <form id="form-search" class="text-c"> 时间：
        <input type="text" onfocus="WdatePicker({ minDate:'%y-%M-\#{%d}',maxDate:'%y-%M-\#{%d+7}',dateFmt:'yyyy-MM-dd HH:mm:ss'})" name="date" id="date" class="input-text Wdate" style="width:180px;" readonly="true">

    <%-----%>
        <%--<input type="text" onfocus="WdatePicker({ minDate:'#F{$dp.$D(\'minDate\')}',maxDate:'%y-%M-%d' })" id="maxDate"--%>
               <%--name="maxDate" class="input-text Wdate" style="width:120px;">--%>

        <button id="searchButton" onclick="chooseTime()" type="button" class="btn btn-success radius" id="" name="">
            确定
        </button>
    </form>
</div>
<!--_footer 作为公共模版分离出去-->
<script type="text/javascript" src="lib/jquery/1.9.1/jquery.min.js"></script>
<script type="text/javascript" src="lib/layer/2.4/layer.js"></script>
<script type="text/javascript" src="static/h-ui/js/H-ui.min.js"></script>
<script type="text/javascript" src="static/h-ui.admin/js/H-ui.admin.js"></script> <!--/_footer 作为公共模版分离出去-->
<script type="text/javascript" src="lib/My97DatePicker/4.8/WdatePicker.js"></script>

<!--请在下方写此页面业务相关的脚本-->
<script type="text/javascript" src="lib/common.js"></script>
<script type="text/javascript">


    /*datatables配置*/


    function chooseTime() {
            var time = $('#date').val()

        time = time.substring(0,19);
        time = time.replace(/-/g,'/');
        var timestamp = new Date(time).getTime();
        console.log(timestamp)
            parent.setTime(timestamp);
            var index = parent.layer.getFrameIndex(window.name);
            parent.layer.close(index);
    }
</script>
</body>
</html>
